package com.tacuati.content;

import java.io.File;

import javax.swing.ImageIcon;

import com.tacuati.Utils;
import com.tacuati.ui.Icons;

public class Unknown extends Item {

	public Unknown(String path) {
		super(path);
		this.setHash(Utils.getHash(path));
		this.setTitle(new File(path).getName());
		this.setFormat(Format.UNKNOWN);
	}

	@Override
	public String toJson() {
		String json = "";
		json += "\"*" + getHash() + "\"";
		return json;
	}

	@Override
	public Item copy() {
		return new PdfBook(this.getPath());
	}
	
	@Override
	public ImageIcon getIcon() {
		return Icons.unknownIcon;
	}
}
